package com.tg.data.http.entity;

import com.tange.base.toolkit.StringUtils;

public class LoginBean {

    /**
     * id : int
     * nickname : string
     * phone : string
     * created_at : timestamp
     * device_num : int
     */

    private String id;
    private String nickname;
    private String phone;
    private long created_at = 0;
    private String device_num = "0";
    private String token;
    private String area_code;

    public String getChannel_id() {
        return channel_id;
    }

    private String channel_id;
    private String channel;

    public String getEmail() {
        return email;
    }

    private String email;

    public boolean isBind(){
        return !StringUtils.isEmpty(token);
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public long getCreated_at() {
        return created_at;
    }

    public void setCreated_at(long created_at) {
        this.created_at = created_at;
    }

    public String getDevice_num() {
        return device_num;
    }

    public void setDevice_num(String device_num) {
        this.device_num = device_num;
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    @Override
    public String toString() {
        return "LoginBean{" +
                "id='" + id + '\'' +
                ", nickname='" + nickname + '\'' +
                ", phone='" + phone + '\'' +
                ", created_at='" + created_at + '\'' +
                ", device_num='" + device_num + '\'' +
                ", token='" + token + '\'' +
                ", channel_id='" + channel_id + '\'' +
                ", channel='" + channel + '\'' +
                ", email='" + email + '\'' +
                '}';
    }

    public String getArea_code() {
        return area_code;
    }

    public void setArea_code(String area_code) {
        this.area_code = area_code;
    }
}
